/*
 * Wazuh databaseFeedManager
 * Copyright (C) 2015, Wazuh Inc.
 * February 28, 2024.
 *
 * This program is free software; you can redistribute it
 * and/or modify it under the terms of the GNU General Public
 * License (version 2) as published by the FSF - Free Software
 * Foundation.
 */

#ifndef _TRAMPOLINE_GLOBAL_DATA_HPP
#define _TRAMPOLINE_GLOBAL_DATA_HPP

#include "MockGlobalData.hpp"
#include "singleton.hpp"

#include "json.hpp"

extern std::shared_ptr<MockGlobalData> spGlobalDataMock;

/**
 * @brief Trampoline class for GlobalData class.
 */
class TrampolineGlobalData final : public Singleton<TrampolineGlobalData>
{
public:
    TrampolineGlobalData() {};
    virtual ~TrampolineGlobalData() = default;

    /**
     * @brief Trampoline to method vendorMaps.
     *
     * @param vendor
     */
    void vendorMaps(const nlohmann::json& vendor)
    {
        spGlobalDataMock->vendorMaps(vendor);
    }

    /**
     * @brief Trampoline to method osCpeMaps.
     *
     * @param osCpe
     */
    void osCpeMaps(const nlohmann::json& osCpe)
    {
        spGlobalDataMock->osCpeMaps(osCpe);
    }

    /**
     * @brief Trampoline to method vendorMaps.
     *
     * @return nlohmann::json
     */
    nlohmann::json vendorMaps() const
    {
        return spGlobalDataMock->vendorMaps();
    }

    /**
     * @brief Trampoline to method osCpeMaps.
     *
     * @return nlohmann::json
     */
    nlohmann::json osCpeMaps() const
    {
        return spGlobalDataMock->osCpeMaps();
    }
};

#endif // _TRAMPOLINE_GLOBAL_DATA_HPP
